home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1995 February: Tool Chest / Dev.CD Feb 95 / Dev.CD Feb 95.toast / Tool Chest / Devices / NuBus⁄Slot Manager / ROM Build⁄Download 3.2.3 / -Read Me next >
Encoding:
Text File  |  1992-09-16  |  2.5 KB  |  66 lines  |  [TEXT/MPS ]

  1. 9/16/92
  2.  
  3. The tools in this folder may make it easier to build declaration ROM images and then  
  4. download those images to a ROM programmer.  Here is a description of the tools in this folder:
  5.  
  6.  
  7.  
  8. 1.  CRCPATCH
  9.  
  10. Calling syntax from the MPW shell: CRCPatch filename 
  11.  
  12. The CRCPatch tool calculates and inserts the CRC value.  It is run after the declaration ROM file 
  13. has been assembled and linked, so that code segment 1 is an image of the declaration ROM.  (There 
  14. will be a code segment 0, but this tool doesn't look at it, and the data tool explained below will 
  15. remove the code 0 segment).  
  16.  
  17. The tool calculates the CRC value of code segment 1 of the specified file, and patches the CRC 
  18. value into the proper position in code segment 1.  Run the CRCPatch tool after assembling and 
  19. linking the declaration ROM.
  20.  
  21. CRCPatch calculates the crc value using this algorithm:
  22.  
  23.     Start pointer at bottom of ROM (top of ROM - length)
  24.     Initialize sum to 0 (sum will be the CRC value)
  25.     @1  Rotate sum left by one bit (with ROL.L #1 instruction)
  26.         If pointer is pointing to CRC field in format header, goto @2 (i.e. don't count CRC field)
  27.         Get a byte
  28.         Add byte to sum
  29.     @2  Increment pointer to next data byte
  30.     Goto @1 until done
  31.  
  32.  
  33.  
  34. 2.  DATA TOOL
  35.  
  36. Calling syntax from the MPW shell: Data ResourceFileName DataFileName
  37.  
  38. The Data tool opens ResourceFileName, strips off the code 0 segment, and puts the code 1 segment in a 
  39. file named DataFileName.  The resulting data file can then be downloaded to a ROM programmer.  
  40. Run the Data tool after doing the CRCPatch.
  41.  
  42. A typical build sequence would be something like:
  43.  
  44.  
  45.     BuildProgram myDeclROM            Assemble, link declaration rom.  The resulting resource 
  46.                                         file will contain code segments 0 and 1.
  47.     CRCPatch myDeclROM                Calculate CRC on code segment 1 and patch value into code 1.
  48.     Data myDeclROM Final.ROM.Image    Copy code segment 1 into data file, creating final rom image.
  49.  
  50.  
  51.  
  52. 3.  TJS COMM APPLICATION
  53.  
  54. The tjs comm application is a rudimentary data comm program.  It can be used to download a
  55. data file to a ROM burner.  The letters TJS are the initials of the engineer who wrote the program.
  56.  
  57.  
  58.  
  59. Changes to this read me file:
  60.  
  61. 7/31/92: Simplified this read me memo, because the Designing Cards and Drivers book contains 
  62. the Slot Manager and ROM concepts that were in the earlier memo.  Removed the MPW 2.0 versions
  63. of the tools.
  64.  
  65. 9/16/92: Added calling syntax, further clarified the need to run CRCPatch, then Data.
  66.